Optimal. Leaf size=42 \[ -\frac{(b c-a d)^2 \log (a+b x)}{a b^2}+\frac{c^2 \log (x)}{a}+\frac{d^2 x}{b} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0312313, antiderivative size = 42, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 18, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.056, Rules used = {72} \[ -\frac{(b c-a d)^2 \log (a+b x)}{a b^2}+\frac{c^2 \log (x)}{a}+\frac{d^2 x}{b} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 72
Rubi steps
\begin{align*} \int \frac{(c+d x)^2}{x (a+b x)} \, dx &=\int \left (\frac{d^2}{b}+\frac{c^2}{a x}-\frac{(-b c+a d)^2}{a b (a+b x)}\right ) \, dx\\ &=\frac{d^2 x}{b}+\frac{c^2 \log (x)}{a}-\frac{(b c-a d)^2 \log (a+b x)}{a b^2}\\ \end{align*}
Mathematica [A] time = 0.0175927, size = 42, normalized size = 1. \[ \frac{-(b c-a d)^2 \log (a+b x)+a b d^2 x+b^2 c^2 \log (x)}{a b^2} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.004, size = 61, normalized size = 1.5 \begin{align*}{\frac{{d}^{2}x}{b}}+{\frac{{c}^{2}\ln \left ( x \right ) }{a}}-{\frac{a\ln \left ( bx+a \right ){d}^{2}}{{b}^{2}}}+2\,{\frac{\ln \left ( bx+a \right ) cd}{b}}-{\frac{\ln \left ( bx+a \right ){c}^{2}}{a}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.04671, size = 72, normalized size = 1.71 \begin{align*} \frac{d^{2} x}{b} + \frac{c^{2} \log \left (x\right )}{a} - \frac{{\left (b^{2} c^{2} - 2 \, a b c d + a^{2} d^{2}\right )} \log \left (b x + a\right )}{a b^{2}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 2.01297, size = 115, normalized size = 2.74 \begin{align*} \frac{a b d^{2} x + b^{2} c^{2} \log \left (x\right ) -{\left (b^{2} c^{2} - 2 \, a b c d + a^{2} d^{2}\right )} \log \left (b x + a\right )}{a b^{2}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] time = 1.10084, size = 73, normalized size = 1.74 \begin{align*} \frac{d^{2} x}{b} + \frac{c^{2} \log{\left (x \right )}}{a} - \frac{\left (a d - b c\right )^{2} \log{\left (x + \frac{a b c^{2} + \frac{a \left (a d - b c\right )^{2}}{b}}{a^{2} d^{2} - 2 a b c d + 2 b^{2} c^{2}} \right )}}{a b^{2}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.25439, size = 74, normalized size = 1.76 \begin{align*} \frac{d^{2} x}{b} + \frac{c^{2} \log \left ({\left | x \right |}\right )}{a} - \frac{{\left (b^{2} c^{2} - 2 \, a b c d + a^{2} d^{2}\right )} \log \left ({\left | b x + a \right |}\right )}{a b^{2}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]